package com.manage.project.biz.service.impl;

import java.util.List;
import com.manage.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.manage.project.biz.mapper.BizJidiansheshijingchangjianxiuMapper;
import com.manage.project.biz.domain.BizJidiansheshijingchangjianxiu;
import com.manage.project.biz.service.IBizJidiansheshijingchangjianxiuService;

/**
 Service业务层处理
 *
 * @author liutao
 *
 */
@Service
public class BizJidiansheshijingchangjianxiuServiceImpl implements IBizJidiansheshijingchangjianxiuService
{
    @Autowired
    private BizJidiansheshijingchangjianxiuMapper bizJidiansheshijingchangjianxiuMapper;

    /**
     * 查询机电设施经常检修
     *
     * @param id 机电设施经常检修主键
     * @return 机电设施经常检修
     */
    @Override
    public BizJidiansheshijingchangjianxiu selectBizJidiansheshijingchangjianxiuById(Long id)
    {
        return bizJidiansheshijingchangjianxiuMapper.selectBizJidiansheshijingchangjianxiuById(id);
    }

    /**
     * 查询机电设施经常检修列表
     *
     * @param bizJidiansheshijingchangjianxiu 机电设施经常检修
     * @return 机电设施经常检修
     */
    @Override
    public List<BizJidiansheshijingchangjianxiu> selectBizJidiansheshijingchangjianxiuList(BizJidiansheshijingchangjianxiu bizJidiansheshijingchangjianxiu)
    {
        return bizJidiansheshijingchangjianxiuMapper.selectBizJidiansheshijingchangjianxiuList(bizJidiansheshijingchangjianxiu);
    }

    /**
     * 新增机电设施经常检修
     *
     * @param bizJidiansheshijingchangjianxiu 机电设施经常检修
     * @return 结果
     */
    @Override
    public int insertBizJidiansheshijingchangjianxiu(BizJidiansheshijingchangjianxiu bizJidiansheshijingchangjianxiu)
    {
        bizJidiansheshijingchangjianxiu.setCreateTime(DateUtils.getNowDate());
        return bizJidiansheshijingchangjianxiuMapper.insertBizJidiansheshijingchangjianxiu(bizJidiansheshijingchangjianxiu);
    }

    /**
     * 修改机电设施经常检修
     *
     * @param bizJidiansheshijingchangjianxiu 机电设施经常检修
     * @return 结果
     */
    @Override
    public int updateBizJidiansheshijingchangjianxiu(BizJidiansheshijingchangjianxiu bizJidiansheshijingchangjianxiu)
    {
        bizJidiansheshijingchangjianxiu.setUpdateTime(DateUtils.getNowDate());
        return bizJidiansheshijingchangjianxiuMapper.updateBizJidiansheshijingchangjianxiu(bizJidiansheshijingchangjianxiu);
    }

    /**
     * 批量删除机电设施经常检修
     *
     * @param ids 需要删除的机电设施经常检修主键
     * @return 结果
     */
    @Override
    public int deleteBizJidiansheshijingchangjianxiuByIds(Long[] ids)
    {
        return bizJidiansheshijingchangjianxiuMapper.deleteBizJidiansheshijingchangjianxiuByIds(ids);
    }

    /**
     * 删除机电设施经常检修信息
     *
     * @param id 机电设施经常检修主键
     * @return 结果
     */
    @Override
    public int deleteBizJidiansheshijingchangjianxiuById(Long id)
    {
        return bizJidiansheshijingchangjianxiuMapper.deleteBizJidiansheshijingchangjianxiuById(id);
    }
}
